package com.pdd.mall.dto;

import jakarta.validation.constraints.Email;
import jakarta.validation.constraints.Pattern;
import jakarta.validation.constraints.Size;
import lombok.Data;

import java.time.LocalDate;

/**
 * 更新用户信息参数
 */
@Data
public class UpdateUserInfoParam {

    // 移除头像字段

    @Size(min = 2, max = 20, message = "昵称长度必须在2-20之间")
    private String nickname;

    @Pattern(regexp = "^1[3-9]\\d{9}$", message = "手机号格式不正确")
    private String phone;

    @Email(message = "邮箱格式不正确")
    private String email;

    private Integer gender;

    private LocalDate birthday;
}
